﻿using Batman.Maintenance.Enums;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;

namespace Batman.Maintenance.DTO
{
    /// <summary>
    /// 数据列表属列
    /// </summary>
    public class MaintenaceColumn
    {
        public string Label { get; set; }

        public string Prop { get; set; }

        [JsonConverter(typeof(StringEnumConverter))]
        public virtual MaintenanceColumnType Type { get; set; }

        public MaintenaceColumn() { }

        public MaintenaceColumn(string label, string prop, MaintenanceColumnType type)
        {
            Label = label;
            Prop = prop;
            Type = type;
        }
    }
}
